import store from "@/store";

function getAirUrl() {
    let mapAddress = store.getters["mapUrl/getMapAddress"]
    //获取不到缓存中的url就使用旧版
    if (mapAddress==undefined ||mapAddress ==false){
        console.log("mapAddress:notExit")
        mapAddress = "http://58.56.209.230:5038/haerbin/20211230dom/{z}/{x}/{y}.png"
    }
    return mapAddress;
}

export default {
    loginTitle: "哈尔滨太平国际机场二期扩建工程北京佳和数字化综合管理平台",
    headerTitle: "哈尔滨太平国际机场二期扩建工程北京佳和数字化综合管理平台",
    companyName: "山东四维",
    companyShortName: "山东四维",
    // 修-改
    urlPath:"/haerbin/Api",
    projectName:"haerbin",
    cityUrlPath:"https://zhihuigongdi.cn/haerbin/Api",
    map: {
        accessToken: "pk.eyJ1IjoiZnV1aG9vIiwiYSI6ImNraThhaHp4YzAzeWMyeWxidTRmbGM1cWYifQ.lqJPXlzfy9frOrpt_JEc9g",
        // 修-改
        center: {lng: 126.247417, lat: 45.626679},
        zoom: 14,
        // 底图1
        baseLayer1URL: "https://t1.tianditu.gov.cn/img_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=img&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=18663b944d2bb97a534d169c391404d5",
        // 底图2
        baseLayer2URL: "https://t5.tianditu.gov.cn/img_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=img&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=18663b944d2bb97a534d169c391404d5",
        // 底图3
        baseLayer3URL: "https://t7.tianditu.gov.cn/img_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=img&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=18663b944d2bb97a534d169c391404d5",
        // 航测图   修-改未替换映射地址
        airUrl: process.env.NODE_ENV === 'production' ? getAirUrl(): "http://58.56.209.230:5038/haerbin/20211230dom/{z}/{x}/{y}.png",
        geoServer: "https://zhihuigongdi.cn/haerbin-tile/geoserver/gwc/service/tms/1.0.0/"
        // geoServer: "http://58.56.207.43:6010/geoserver/gwc/service/tms/1.0.0/"
    },
    craft: {
        // 碾压
        compaction: {
            mqtt:{
                ip: "wss://zhihuigongdi.cn/mqtt",
                topic: "HaErBin/Comp/WebData/",
                userName: "HaErBin_web",
                password: "HaErBin_web"
            }
        },
        // 强夯
        tamp: {
            mqtt:{
                ip: "wss://zhihuigongdi.cn/mqtt",
                topic: "HaErBin/Tamp/WebData/",
                userName: "HaErBin_web",
                password: "HaErBin_web"
            }
        },
        // CFG
        cfg: {
            mqtt:{
                ip: "wss://zhihuigongdi.cn/mqtt",
                topic: "HaErBin/CFG/WebData/",
                userName: "HaErBin_web",
                password: "HaErBin_web"
            }
        },
        // 旋挖钻
        rotary: {
            mqtt:{
                ip: "wss://zhihuigongdi.cn/mqtt",
                topic: "HaErBin/Rotary/WebData/",
                userName: "HaErBin_web",
                password: "HaErBin_web"
            }
        },
        // 摊铺碾压
        paver: {
            comp_mqtt:{
                ip: "wss://zhihuigongdi.cn/mqtt",
                topic: "HaErBin/Comp/WebData/",
                userName: "HaErBin_web",
                password: "HaErBin_web"
            },
            paver_mqtt:{
                ip: "wss://zhihuigongdi.cn/mqtt",
                topic: "HaErBin/Pave/WebData/",
                userName: "HaErBin_web",
                password: "HaErBin_web"
            }
        },
        // 水泥搅拌桩
        cement: {
            mqtt:{
                ip: "wss://zhihuigongdi.cn/mqtt",
                topic: "HaErBin/Cement/WebData/",
                userName: "HaErBin_web",
                password: "HaErBin_web"
            }
        },
        // 拌合站
        mix: {},
        // 洒水车
        water: {
            mqtt:{
                ip: "wss://zhihuigongdi.cn/mqtt",
                topic: "HaErBin/Water/",
                userName: "HaErBin_web",
                password: "HaErBin_web"
            }
        },
        // 车辆管理
        vehicle: {
            mqtt:{
                ip: "wss://zhihuigongdi.cn/mqtt",
                topic: "vehicle/HaErBin/",
                userName: "HaErBin_web",
                password: "HaErBin_web"
            }
        }
    }
}

